use "$data/figure_A2_input.dta", clear

	xtile sizetile = irr_share_total2001, nq(100)
	reg pct_irrigated irr_share_total, cluster(mca)
	collapse (mean) pct_irrigated irr_share_total2001, by(sizetile)
		reg pct_irrigated irr_share_total2001, cluster(sizetile)

	twoway (scatter pct_irrigated irr_share_total2001, mcolor(black) msymbol(circle_hollow) ytitle(Share of area irrigated (Village Census 2001)) ///
	xtitle(Share of area irrigated ( AIS )) msize(medsmall)) || (lfit pct_irrigated irr_share_total2001, lcolor(blue) legend(off)) , ylabel(,nogrid) graphregion(color(white)) || (function y = x, ra(irr_share_total2001) clpat(dash) lcolor(gray)) 
	graph export "$results/graphs/figure_A2.pdf", as(pdf) replace
